<%-- 
    Document   : admin_suadiem
    Created on : Oct 7, 2012, 2:07:18 PM
    Author     : TienNT
--%>

<%@page import="tuyensinh.BangDiem"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@include file="admin_menu.jsp" %>
<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>JSP Page</title>
    </head>
    <body>
        <form action="/TuyenSinh/XuLy" method="post">
            Nhap so bao danh cua thi sinh: 
            <input type="text" name="sbd">
            <input type="hidden" name="yc" value="admin_suadiem_sbd">
            <input type="submit" value="Tim thi sinh">
        </form>
        <br>
        <br>
        <%
            String tb = (String) request.getAttribute("tb");
            if (tb == null) {
                tb = "";
            }
            BangDiem bd = (BangDiem) request.getSession().getAttribute("bangdiem");
            String status = "table";
            String sbd = "";
            float diemmon1 = 0, diemmon2 = 0, diemmon3 = 0;
            if (bd == null) {
                status = "none";
            } else {
                sbd = bd.getSbd();
                diemmon1 = bd.getDiemmon1();
                diemmon2 = bd.getDiemmon2();
                diemmon3 = bd.getDiemmon3();
            }
        %>
        <%=tb%>
        <form action="/TuyenSinh/XuLy" method="post">
            <table style="display: <%=status%>">
                <tbody>
                    <tr>
                        <th>So bao danh: </th>
                        <td><%=sbd%></td>
                    </tr>
                    <tr>
                        <th>Diem mon 1: </th>
                        <td><input type="text" name="diemmon1" value="<%=diemmon1%>"></td>
                    </tr>
                    <tr>
                        <th>Diem mon 2: </th>
                        <td><input type="text" name="diemmon2" value="<%=diemmon2%>"></td>
                    </tr>
                    <tr>
                        <th>Diem mon 3: </th>
                        <td><input type="text" name="diemmon3" value="<%=diemmon3%>"></td>
                    </tr>
                    <tr>
                        <td colspan="2" style="text-align: center">
                            <input type="hidden" name="sbd" value="<%=sbd%>">
                            <input type="hidden" name="yc" value="admin_suadiem_diem">
                            <input type="submit" value="Sua diem">
                        </td>
                    </tr>
                </tbody>
            </table>
        </form>
    </body>
</html>
